<!DOCTYPE html>
<html lang="cn-ZH">

<head>  
    <meta charset="UTF-8">
    <title>表格</title>
    <style>
        th, td {
            text-align: center; /* 水平居中对齐 */
            vertical-align: middle; /* 垂直居中对齐 */
            border: 1px solid black; /* 为单元格添加边框 */
        }
        table {
            border-collapse: collapse; /* 合并边框 */
            border: 1px solid black; /* 为表格添加边框 */
            width: 100%; /* 设置表格宽度为100% */;
            height: auto; /* 设置表格高度为100% */;
        }
        /* 为表头单元格添加背景颜色 */
        thead th {
            background-color: #4CAF50; /* 可以根据需要修改颜色值 */
            color: white; /* 设置文字颜色，提高对比度 */
            height: 30px; /* 设置表头单元格的高度 */;
        }
    </style>
</head>

<body>
    <table>
        <caption>学生信息</caption>
        <thead>
            <tr>
                <th>姓名</th>
                <th>年龄</th>
                <th>性别</th>
                <th>民族</th>
                <th>政治面貌</th>
            </tr>
        </thead>
            <tr>
                <td>张三</td>
                <td>18</td>
                <td>男</td>
                <td>汉族</td>
                <td>党员</td>
            </tr>
            <tr>
                <td>李四</td>
                <td>19</td>
                <td>女</td>
                <td>苗族</td>
                <td>群众</td>
            </tr>
        
        <tbody>

        </tbody>
    </table>
    
    </tbody>
    <table>
        <caption>课程表</caption>
        <thead>
            <tr>
                <th>1-1</th>
                <th colspan="2">1-2</th>
                <!-- <th>1-3</th> -->
                <th>1-4</th>
                <th>1-5</th>
            </tr>
        </thead>
        <tbody>
            <tr>
                <td rowspan="2">2-1</td>
                <td>2-2</td>
                <td>2-3</td>
                <td>2-4</td>
                <td>2-5</td>
            </tr>
            <tr>
                <!-- <td>3-1</td>     -->
                <td>3-2</td>
                <td>3-3</td>
                <td>3-4</td>
                <td>3-5</td>
            </tr>
            <tr>
                <td>4-1</td>
                <td>4-2</td>
                <td>4-3</td>
                <td>4-4</td>
                <td>4-5</td>
            </tr>
            <tr>
                <td>5-1</td>
                <td>5-2</td>
                <td>5-3</td>
                <td>5-4</td>
                <td>5-5</td>
            </tr>
            <tr>
                <td>6-1</td>
                <td>6-2</td>
                <td>6-3</td>    
                <td>6-4</td>
                <td>6-5</td>
            </tr>
            <tr>
                <td>7-1</td>
                <td>7-2</td>
                <td>7-3</td>
                <td>7-4</td>
                <td>7-5</td>
            </tr>
        </tbody>
        
    </table>
</body>
</html>